package com.zengfa.task.api.enums;

public enum RunType {

	/**
	 * 异步
	 */
	ASYNC(1),
	
	/**
	 * 同步
	 */
	SYNC(2),
	;
	
	private Integer value;
	public Integer getValue() {
		return this.value;
	}
	
	RunType(Integer value){
		this.value = value;
	}
	
	public static RunType valueOf(Integer value) {
		for (RunType constant : RunType.class.getEnumConstants()) {
    		if(constant.getValue().equals(value)) {
    			return constant;
    		}
    	}
    	return null;
	}
}
